package com.compus_help.entity.Pojo;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.annotation.JsonProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.time.LocalDateTime;

@NoArgsConstructor
@AllArgsConstructor
public class Notice {
    /**
     * 公告ID（主键）
     */
    private Integer noticeId;

    /**
     * 公告标题
     */
    private String title;

    /**
     * 公告状态
     */
    private String status;

    /**
     * 公告详情
     */
    private String content;
    /**
     * 联系方式（可选）
     */
    private String contact;


    private Boolean isTop;

    /**
     * 发布时间
     */
    private LocalDateTime publishTime;

    //生效时间
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonProperty("effective_time")
    private LocalDateTime effectiveTime;
    //失效时间
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonProperty("expire_time")
    private LocalDateTime expireTime;
    //更新时间
    private LocalDateTime updateTime;
    // Getters and Setters

    public Integer getNoticeId() {
        return noticeId;
    }

    public void setNoticeId(Integer noticeId) {
        this.noticeId = noticeId;
    }

    public String getTitle() {
        return title;
    }

    public void setTitle(String title) {
        this.title = title;
    }

    public String getStatus() {
        return status;
    }

    public void setStatus(String status) {
        this.status = status;
    }

    public String getContent() {
        return content;
    }

    public void setContent(String content) {
        this.content = content;
    }

    public String getContact() {
        return contact;
    }

    public void setContact(String contact) {
        this.contact = contact;
    }


public Boolean getIsTop() {
    return isTop;
}

public void setIsTop(Boolean isTop) {
    this.isTop = isTop;
}


    public LocalDateTime getPublishTime() {
        return publishTime;
    }

    public void setPublishTime(LocalDateTime publishTime) {
        this.publishTime = publishTime;
    }

    public LocalDateTime getEffectiveTime() {
        return effectiveTime;
    }

    public void setEffectiveTime(LocalDateTime effectiveTime) {
        this.effectiveTime = effectiveTime;
    }

    public LocalDateTime getExpireTime() {
        return expireTime;
    }

    public void setExpireTime(LocalDateTime expireTime) {
        this.expireTime = expireTime;
    }

    public LocalDateTime getUpdateTime() {
        return updateTime;
    }

    public void setUpdateTime(LocalDateTime updateTime) {
        this.updateTime = updateTime;
    }
}
